#include<bits/stdc++.h>
#define ll long long
#define For(i, a, b) for (int i = a; i <= b; i++)
#define For1(i, a, b) for (int i = a; i >= b; i--)
using namespace std;
inline int read(){
    int sum = 0, fh = 1; char ch = getchar();
    while (!isdigit(ch)) {if (ch == '-') fh = -1; ch = getchar();}
    while (isdigit(ch)) {sum = sum * 10 + ch - '0'; ch = getchar();}
    return sum * fh;
}
inline void write(int x){
    if (x == 0){putchar('0'); return ;}stack<char> s;
    if (x < 0) {putchar('-'); x = -x;}
    while(x) {s.push(x % 10 + '0'); x /= 10;}
    while(!s.empty()) {putchar(s.top()); s.pop();}
}
const int MAXN = 1e5 + 10;
int n, a[MAXN];
signed main()
{
    freopen("duel.in", "r", stdin);
    freopen("duel.out", "w", stdout);
    n = read();
    For(i, 1, n)
    {
        a[i] = read();
    }
    sort(a + 1, a + n + 1);
    int ans = 1;
    int pre = 2;
    For(i, 1, n)
    {
        while (pre <= n && a[pre] <= a[i])
        {
            pre++;
            ans++;
        }
        pre++;
        if (pre > n) break;
    }
    cout << ans;
    return 0;
}